<template>
  <div class="box"></div>
</template>

<script lang="ts" setup>
import { onMounted, ref } from "vue";
import { gsap } from "gsap";
const obj = ref({ myNum: 10, myColor: "red" });
function move() {
    gsap.to(".box", { duration:3, x: 300,repeat:2 ,ease:'steps.out'})
  //   gsap.from(".box", { duration:3, x: 100 });
  //   gsap.set(".box", {  x: 100,fill:'blue', });
//   gsap.to(obj.value,{
//     myNum:200,
//     myColor:'blue',
//     onUpdate:()=>{
//         console.log(obj.value,17);
        
//     }
//   })

}
onMounted(() => {
  move();
});
</script>
<style lang="scss" scoped>
.box {
  width: 50px;
  height: 50px;
  border: 1px solid red;
}
</style>
